//
//  WDButton.m
//  Zhihuijinfu
//
//  Created by 王笛 on 2016/12/25.
//  Copyright © 2016年 王笛. All rights reserved.
//

#import "WDButton.h"

@implementation WDButton

- (instancetype)initWithFrame:(CGRect)frame
{
    if (self = [super initWithFrame:frame]) {
        
    }
    return self;
}

- (void)layoutSubviews
{
    [super layoutSubviews];
    
    self.imageView.frame = CGRectMake(0, 0, self.bounds.size.width, self.bounds.size.width);
    self.imageView.layer.cornerRadius = self.bounds.size.width *0.5;
    self.imageView.clipsToBounds = YES;
    
    self.titleLabel.frame = CGRectMake(0, self.bounds.size.width, self.bounds.size.width, self.bounds.size.height - self.bounds.size.width);
}

@end
